ADFA-5404 | Recover from missing offline language packs - #95
Open
jatezzz wants to merge 4 commits into
Open
Conversation
…A-5404) Recognize in the host's configured locale, and on error 12/13 retry once with an installed pack for the same language or online while fetching the missing pack, instead of failing the capture with "unknown error 12".
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review for a one-time review, or @claude review always to subscribe this PR to a review on every future push.
Tip: disable this comment in your organization's Code Review settings.
jatezzz
requested review from
a team,
Daniel-ADFA,
dara-abijo-adfa and
itsaky-adfa
September 9, 2026 19:53
Contributor
|
I posted on Slack about strings.xml review |
Teardown conflict resolved: deactivate() now calls teardown(), which releases the capture via endCapture() instead of destroyRecognizer().
Derive STALE_CAPTURE_MS from the generation timeout so the busy guard cannot expire first, and skip the just-failed tag when matching an installed language pack so the retry cannot repeat the same request.
…x/ADFA-5404-language-pack-error-handling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Replaces the generic "unknown error 12" with clear, actionable UI messages that display the specific missing Locale. Implements an automatic single online retry when an offline language pack is missing, ensuring the user's dictation session stays alive without being prematurely aborted.
Details
ERROR_LANGUAGE_UNAVAILABLEandERROR_LANGUAGE_NOT_SUPPORTEDinSpeechToTextPlugin.kt.preferOfflineand setEXTRA_LANGUAGEto support a single online retry attempt.strings.xmlto inform the user of the exact failing language and the fallback network attempt.index.htmldocumentation to reflect the new language pack recovery behavior.Prompt EN:
Function that reverses a stringPrompt ES:
Función que reversa un stringdocument_4976756881377724759.mp4
Ticket
ADFA-5404
Parent: ADFA-5402
Observation
The plugin now queries
checkRecognitionSupporton API 33+ devices to find regional fallback packs or trigger downloads, defaulting to a direct network retry on older SDKs.